package com.mydomain.Bodega;

import com.mydomain.Bodega.*;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.framework.EntityQuery;
import java.util.Arrays;

@Name("invEgresoTransList")
public class InvEgresoTransList extends EntityQuery<InvEgreso> {

	private String EJBQL = "select invEgreso from InvEgreso invEgreso,Subdepartamento s where invEgreso.egrTipo='EGRESO_TRANSFERENCIA' and s.subdepCodigo=invEgreso.egrSubdep";

	private static final String[] RESTRICTIONS = {
			"lower(invEgreso.egrObservacion) like concat(lower(#{invEgresoList.invEgreso.egrObservacion}),'%')",
			"lower(invEgreso.egrTipoPago) like concat(lower(#{invEgresoList.invEgreso.egrTipoPago}),'%')", };

	private InvEgreso invEgreso = new InvEgreso();

	public InvEgresoTransList() {
		setEjbql(EJBQL);
		setRestrictionExpressionStrings(Arrays.asList(RESTRICTIONS));
		setMaxResults(25);
	}

	public InvEgreso getInvEgreso() {
		return invEgreso;
	}

}
